package com.example.exception;

import com.example.model.AppExceptioncodeMsg;

public class AppException extends RuntimeException {

    private int code;
    private String msg;

    public AppException() {
    }
    public AppException(AppExceptioncodeMsg appExceptioncodeMsg) {
        this.code=appExceptioncodeMsg.getCode();
        this.msg = appExceptioncodeMsg.getMsg();
    }


    public AppException(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public int getCode() {
        return code;
    }

    public String getMsg() {
        return msg;
    }
}
